<template>
    <div class="icon">
       <div class="left"></div>
       <div class="right">
        <!-- 文本插值 模板语法 -->
        {{props.title}}
       </div>
    </div>
</template>

<script setup>
import{defineProps} from 'vue';
//子组件接受父组件传递的内容
const props = defineProps(['title'])
</script>

<style lang="less">
    .icon{ 
        display: flex;
        .left{
            margin-right: 10px;
            width: 24px;
        height: 30px;
        background-image: url('../../assets/layout/box_title_icon.png');
        background-size: 100% 100%;
        }
    }
</style>